<?php
 
include('connection.php');
if(isset($_POST['eventname']) )
{
	
	$title=$_POST['eventname'];
	$start_date=$_POST['start_date'];
	$expire_date=$_POST['expire_date'];
	$description=$_POST['description'];
	$status=$_POST['status'];
	
$sql = "INSERT INTO event(title,start_date,expire_date,description,status)VALUES('$title','$start_date','$expire_date','$description','$status')";

$retval = mysql_query($sql,$con);
if(! $retval )
{
  die('Could not enter data: ' . mysql_error());
}

echo "Your data are submited successfully.";

}
if(isset($_POST['course_name']) )
{
	
	$course_name=$_POST['course_name'];
	$course_fees=$_POST['course_fees'];
	$course_duration=$_POST['course_duration'];
	
	
$sql = "INSERT INTO course(course_name,course_fees,course_duration)VALUES('$course_name','$course_fees','$course_duration')";

$retval = mysql_query($sql,$con);
if(! $retval )
{
  die('Could not enter data: ' . mysql_error());
}

echo "Your data are submited successfully.";

}

?>